#!/bin/csh -f

if ( $#argv < 2 ) then
    echo "Usage: $0 file-extension sub-dir [subdir ...]"
    exit 1
endif

set statcmd="svn status"
set ext=$1
shift

foreach dir ( $* )
    if ( -d $dir && "$dir" != "CVS" ) then
	echo "$dir ..."
	cd $dir
	$statcmd *.$ext |& grep '\?'
	cd ..
    endif
end

